<?php
ini_set ( "session.use_cookies", 0 );
ini_set ( "session.use_only_cookies", 0 );
ini_set ( "session.use_trans_sid", 1 );
session_start ();
if (isset ( $_SESSION ['nVisitas'] )) {
	$_SESSION ['nVisitas'] = $_SESSION ['nVisitas'] + 1;
} else {
	$_SESSION ['nVisitas'] = 1;
}

echo "<h1>Visitas: {$_SESSION['nVisitas']} </h1>";
?>
<html>
<head>
<title>Contador</title>
<style>
body {
	margin: 30px;
}
</style>
</head>
<body>
	<form method="post">
		<input type="submit" value="Enviar Formulario">
	</form>
</body>
</html>